#!/usr/bin/perl

=head1 NAME

Swignition::DataModel::BlankNode - A non-literal RDF resource without a URI.

=cut

package Swignition::DataModel::BlankNode;

use Swignition::DataModel::Node;

use constant TRUE      =>  1;
use constant FALSE     =>  0;
use strict;

our @ISA = ("Swignition::DataModel::Node");
our $VERSION = '0.1';

=head1 CONSTRUCTORS

=over

=item $node = Swignition::DataModel::BlankNode->new($model)

Create a new node. 

=cut

sub new
{
	my $class = shift;
	my $model = shift;
	
	my $this = Swignition::DataModel::Node::new(__PACKAGE__, $model);

	return $this;
}

=back

=head1 PUBLIC METHODS

C<Swignition::DataModel::BlankNode> also inherits from C<Swignition::DataModel::Node>.

=over

=item $node->promote($uri)

Makes this node into a full Swignition::DataModel::Resource by assigning
it a URI.

=cut

sub promote
{
	my $this = shift;
	my $uri  = shift;
	
	my $rv   = $this->add_uri($uri, 10);
	bless $rv, 'Swignition::DataModel::Resource';
}

=back

=cut

1;

